package com.grades.springboot.controller;

import com.grades.springboot.entity.Result;
import com.grades.springboot.service.impl.UserInfoServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletRequest;

@RestController
@RequestMapping("/info")
public class UserInfoController {

    @Autowired
    private UserInfoServiceImpl userInfoService;

    @GetMapping("/")
    public Result<?> getInfo(HttpServletRequest request){
        return userInfoService.getInfo(request);
    }
}
